inherited fmOfficialNote: TfmOfficialNote
  Left = 264
  Top = 317
  Width = 1280
  Height = 695
  Caption = #1057#1083#1091#1078#1077#1073#1085#1099#1077' '#1079#1072#1087#1080#1089#1082#1080
  Constraints.MinHeight = 695
  Constraints.MinWidth = 1280
  OnShow = FormShow
  PixelsPerInch = 96
  TextHeight = 13
  inherited sbBottom: TStatusBar
    Top = 630
    Width = 1264
  end
  inherited Panel1: TPanel
    Width = 1264
    Visible = False
    inherited BitBtn1: TBitBtn
      Left = 1078
    end
    inherited BitBtn2: TBitBtn
      Left = 1166
    end
  end
  object dbgPeople: TcxGrid [2]
    Left = 0
    Top = 74
    Width = 497
    Height = 556
    Align = alLeft
    Font.Charset = DEFAULT_CHARSET
    Font.Color = clWindowText
    Font.Height = -13
    Font.Name = 'Tahoma'
    Font.Style = []
    ParentFont = False
    TabOrder = 2
    LookAndFeel.Kind = lfStandard
    object tvPeople: TcxGridDBTableView
      NavigatorButtons.ConfirmDelete = False
      NavigatorButtons.PriorPage.Visible = True
      NavigatorButtons.Next.Visible = True
      NavigatorButtons.Insert.Visible = True
      NavigatorButtons.Append.Visible = False
      NavigatorButtons.Edit.Visible = False
      NavigatorButtons.Post.Visible = True
      NavigatorButtons.Cancel.Visible = False
      NavigatorButtons.Refresh.Visible = False
      NavigatorButtons.SaveBookmark.Visible = False
      NavigatorButtons.GotoBookmark.Visible = False
      NavigatorButtons.Filter.Visible = False
      DataController.DataSource = dsPON
      DataController.Summary.DefaultGroupSummaryItems = <>
      DataController.Summary.FooterSummaryItems = <
        item
          Format = '#,###0'
          Kind = skSum
          FieldName = 'ITOGO'
          Column = tvPeopleITOGO
        end
        item
          Format = '#,###0'
          Kind = skSum
          FieldName = 'SUM_'
          Column = tvPeopleSUM_
        end
        item
          Kind = skCount
          FieldName = 'PP'
          Column = tvPeoplePP
        end
        item
          Format = '#,###0'
          Kind = skSum
          FieldName = 'NE_VYPL'
          Column = tvPeopleNE_VYPL
        end>
      DataController.Summary.SummaryGroups = <>
      OptionsBehavior.CellHints = True
      OptionsCustomize.ColumnFiltering = False
      OptionsData.CancelOnExit = False
      OptionsData.Deleting = False
      OptionsData.DeletingConfirmation = False
      OptionsData.Inserting = False
      OptionsView.CellEndEllipsis = True
      OptionsView.NoDataToDisplayInfoText = '<'#1053#1077#1090' '#1076#1072#1085#1085#1099#1093'>'
      OptionsView.CellAutoHeight = True
      OptionsView.CellTextMaxLineCount = 1
      OptionsView.ColumnAutoWidth = True
      OptionsView.Footer = True
      OptionsView.GroupByBox = False
      OptionsView.HeaderEndEllipsis = True
      OptionsView.Indicator = True
      Preview.Visible = True
      Styles.Header = DMInv.cxSiniyText
      object tvPeoplePP: TcxGridDBColumn
        Caption = #1060#1048#1054' '#1087#1086#1083#1091#1095#1072#1090#1077#1083#1103
        DataBinding.FieldName = 'PP'
        Options.Editing = False
        Width = 259
      end
      object tvPeopleSUM_: TcxGridDBColumn
        Caption = #1048#1090#1086#1075#1086' '#1079#1072' '#1090#1077#1082'. '#1091#1095'. '#1075#1086#1076
        DataBinding.FieldName = 'SUM_'
        Options.Editing = False
        Width = 202
      end
      object tvPeopleITOGO: TcxGridDBColumn
        Caption = #1048#1090#1086#1075#1086' '#1079#1072' '#1087#1077#1088#1080#1086#1076
        DataBinding.FieldName = 'ITOGO'
        Options.Editing = False
        Width = 209
      end
      object tvPeopleNE_VYPL: TcxGridDBColumn
        Caption = #1045#1097#1077' '#1085#1077' '#1088#1072#1089#1089#1084'.'
        DataBinding.FieldName = 'NE_VYPL'
        Options.Editing = False
      end
      object tvPeopleKVYPLATE: TcxGridDBColumn
        Caption = #1053#1072#1076#1086' '#1074#1099#1087#1083#1072#1090#1080#1090#1100
        DataBinding.FieldName = 'KVYPLATE'
        Options.Editing = False
      end
    end
    object cxGridLevel2: TcxGridLevel
      GridView = tvPeople
    end
  end
  object ToolBar1: TToolBar [3]
    Left = 0
    Top = 45
    Width = 1264
    Height = 29
    ButtonWidth = 25
    Caption = 'ToolBar1'
    Images = DMInv.ilActive
    TabOrder = 3
    DesignSize = (
      1264
      27)
    object tbAddON: TToolButton
      Left = 0
      Top = 2
      Hint = #1057#1086#1079#1076#1072#1090#1100' '#1089#1083#1091#1078'. '#1079#1072#1087#1080#1089#1082#1091
      Caption = 'tbAddON'
      ImageIndex = 28
      ParentShowHint = False
      ShowHint = True
      OnClick = tbAddONClick
    end
    object tbEditON: TToolButton
      Left = 25
      Top = 2
      Hint = #1056#1077#1076#1072#1082#1090#1080#1088#1086#1074#1072#1090#1100' c'#1083#1091#1078'. '#1079#1072#1087#1080#1089#1082#1091
      Caption = 'tbEditON'
      ImageIndex = 2
      ParentShowHint = False
      ShowHint = True
      OnClick = tbEditONClick
    end
    object tbDelON: TToolButton
      Left = 50
      Top = 2
      Hint = #1059#1076#1072#1083#1080#1090#1100' c'#1083#1091#1078'. '#1079#1072#1087#1080#1089#1082#1091
      Caption = 'tbDelON'
      ImageIndex = 29
      ParentShowHint = False
      ShowHint = True
      OnClick = tbDelONClick
    end
    object tbRefresh: TToolButton
      Left = 75
      Top = 2
      Hint = #1054#1073#1085#1086#1074#1080#1090#1100
      Caption = 'tbRefresh'
      ImageIndex = 8
      ParentShowHint = False
      ShowHint = True
      OnClick = tbRefreshClick
    end
    object tbExcel: TToolButton
      Left = 100
      Top = 2
      Hint = #1069#1082#1089#1087#1086#1088#1090
      Caption = 'tbExcel'
      ImageIndex = 16
      ParentShowHint = False
      ShowHint = True
      OnClick = tbExcelClick
    end
    object ToolButton6: TToolButton
      Left = 125
      Top = 2
      Width = 8
      Caption = 'ToolButton6'
      ImageIndex = 14
      Style = tbsSeparator
    end
    object tbAddEditTabel: TToolButton
      Left = 133
      Top = 2
      Hint = #1056#1072#1073#1086#1090#1072' '#1089' '#1090#1072#1073#1077#1083#1077#1084
      Caption = 'tbAddEditTabel'
      ImageIndex = 15
      ParentShowHint = False
      ShowHint = True
      OnClick = tbAddEditTabelClick
    end
    object tbDengi: TToolButton
      Left = 158
      Top = 2
      Caption = #1042#1099#1076#1072#1090#1100' '#1076#1077#1085#1100#1075#1080
      ImageIndex = 43
      Visible = False
      OnClick = tbDengiClick
    end
    object ToolButton2: TToolButton
      Left = 183
      Top = 2
      Width = 8
      Caption = 'ToolButton2'
      ImageIndex = 16
      Style = tbsSeparator
    end
    object ToolButton1: TToolButton
      Left = 191
      Top = 2
      Width = 8
      Caption = 'ToolButton1'
      ImageIndex = 15
      Style = tbsSeparator
    end
    object cxLabel1: TcxLabel
      Left = 199
      Top = 4
      Caption = #1055#1077#1088'.'#1076#1083#1103' '#1072#1085#1072#1083#1080#1090'.'
    end
    object eDate: TcxButtonEdit
      Tag = 11
      Left = 288
      Top = 2
      ParentFont = False
      Properties.Buttons = <
        item
          Glyph.Data = {
            F6000000424DF600000000000000760000002800000010000000100000000100
            0400000000008000000000000000000000001000000000000000000000000000
            8000008000000080800080000000800080008080000080808000C0C0C0000000
            FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00FFFFFFFFFFFF
            FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
            FFFFFFFFFFF0FFFFFFFFFFFFFF000FFFFFFFFFFFF00000FFFFFFFFFF0000000F
            FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
            FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF}
        end>
      Properties.MaxLength = 0
      Properties.ReadOnly = True
      Properties.OnButtonClick = eDatePropertiesButtonClick
      Properties.OnChange = eDatePropertiesChange
      Style.Font.Charset = DEFAULT_CHARSET
      Style.Font.Color = clWindowText
      Style.Font.Height = -13
      Style.Font.Name = 'Tahoma'
      Style.Font.Style = [fsBold]
      Style.LookAndFeel.SkinName = ''
      Style.Shadow = False
      Style.IsFontAssigned = True
      StyleDisabled.LookAndFeel.SkinName = ''
      StyleFocused.LookAndFeel.SkinName = ''
      StyleHot.LookAndFeel.SkinName = ''
      TabOrder = 0
      Width = 196
    end
    object cxLabel2: TcxLabel
      Left = 484
      Top = 4
      Caption = #1055#1077#1088#1080#1086#1076' '#1076#1083#1103' '#1089#1083#1091#1078#1077#1073#1086#1082
    end
    object eDateZ: TcxButtonEdit
      Tag = 11
      Left = 600
      Top = 2
      ParentFont = False
      Properties.Buttons = <
        item
          Glyph.Data = {
            F6000000424DF600000000000000760000002800000010000000100000000100
            0400000000008000000000000000000000001000000000000000000000000000
            8000008000000080800080000000800080008080000080808000C0C0C0000000
            FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00FFFFFFFFFFFF
            FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
            FFFFFFFFFFF0FFFFFFFFFFFFFF000FFFFFFFFFFFF00000FFFFFFFFFF0000000F
            FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
            FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF}
        end>
      Properties.MaxLength = 0
      Properties.ReadOnly = True
      Properties.OnButtonClick = eDateZPropertiesButtonClick
      Properties.OnChange = eDatePropertiesChange
      Style.Font.Charset = DEFAULT_CHARSET
      Style.Font.Color = clWindowText
      Style.Font.Height = -13
      Style.Font.Name = 'Tahoma'
      Style.Font.Style = [fsBold]
      Style.LookAndFeel.SkinName = ''
      Style.Shadow = False
      Style.IsFontAssigned = True
      StyleDisabled.LookAndFeel.SkinName = ''
      StyleFocused.LookAndFeel.SkinName = ''
      StyleHot.LookAndFeel.SkinName = ''
      TabOrder = 3
      Width = 206
    end
    object cxLabel3: TcxLabel
      Left = 806
      Top = 4
      Caption = #1057#1090#1072#1090#1091#1089
    end
    object cbStatus: TcxComboBox
      Left = 846
      Top = 2
      Properties.Items.Strings = (
        #1042#1089#1077
        #1053#1077' '#1088#1072#1089#1089#1084#1086#1090#1088#1077#1085#1086
        #1056#1072#1089#1089#1084#1086#1090#1088#1077#1085#1086
        #1054#1090#1082#1072#1079#1072#1085#1086)
      Properties.OnCloseUp = eDatePropertiesChange
      TabOrder = 4
      Text = #1053#1077' '#1088#1072#1089#1089#1084#1086#1090#1088#1077#1085#1086
      Width = 121
    end
    object bGridCust: TcxButton
      Tag = 12
      Left = 967
      Top = 2
      Width = 27
      Height = 22
      Hint = #1050#1086#1083#1086#1085#1082#1080' '#1090#1072#1073#1083#1080#1094#1099
      Anchors = [akTop, akRight]
      ParentShowHint = False
      ShowHint = True
      TabOrder = 9
      TabStop = False
      OnClick = bGridCustClick
      Glyph.Data = {
        76010000424D7601000000000000760000002800000020000000100000000100
        04000000000000010000120B0000120B00001000000000000000000000000000
        80000080000000808000800000008000800080800000C0C0C000808080000000
        FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00333333333333
        33333FFFFFFFFFFFFFFF000000000000000088888888888888880FFFFFFFFFFF
        FFF08F3FF3FF3FF7FFF80F00F00F00F900F08F883883883788380FFFFFFFF9FF
        FFF08F3FF3FF37F3FFF80F00F00F09F000F08F883883873888380FFFFFFFF99F
        FFF08F3FF3FF3773FFF80F00F99909F000F08F883777873888380FFFF9FFF999
        FFF08F3FF7FF3777FFF80F00F99F00F000F08F88377388388838099FF9FFFFFF
        FFF0877FF7FFFFFFFFF809C9C999CCCCCCC087878777888888880979CCCCCCCC
        C77087F7888888888FF809090000000000008787888888888888399333333333
        3333377333333333333333333333333333333333333333333333}
      LookAndFeel.SkinName = 'Blue'
      NumGlyphs = 2
    end
    object bVypl: TcxButton
      Left = 994
      Top = 2
      Width = 66
      Height = 22
      Anchors = [akTop, akRight]
      Caption = #1042#1099#1087#1083#1072#1090#1080#1090#1100
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWhite
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      ParentFont = False
      TabOrder = 7
      Visible = False
      OnClick = bVyplClick
      Colors.Default = clTeal
    end
    object bvyplInujusummu: TcxButton
      Left = 1060
      Top = 2
      Width = 135
      Height = 22
      Anchors = [akTop, akRight]
      Caption = #1042#1099#1087#1083#1072#1090#1080#1090#1100' '#1080#1085#1091#1102' '#1089#1091#1084#1084#1091
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clBlack
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      ParentFont = False
      TabOrder = 6
      Visible = False
      OnClick = bvyplInujusummuClick
      Colors.Default = clMoneyGreen
    end
    object bOtkaz: TcxButton
      Left = 1195
      Top = 2
      Width = 65
      Height = 22
      Anchors = [akTop, akRight]
      Caption = #1054#1090#1082#1072#1079#1072#1090#1100
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWhite
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      ParentFont = False
      TabOrder = 8
      Visible = False
      OnClick = bOtkazClick
      Colors.Default = clPurple
      LookAndFeel.SkinName = ''
    end
  end
  object cxSplitter1: TcxSplitter [4]
    Left = 497
    Top = 74
    Width = 8
    Height = 556
    HotZoneClassName = 'TcxMediaPlayer9Style'
    Control = dbgPeople
  end
  object dbgON: TcxGrid [5]
    Left = 505
    Top = 74
    Width = 759
    Height = 556
    Align = alClient
    Font.Charset = DEFAULT_CHARSET
    Font.Color = clWindowText
    Font.Height = -13
    Font.Name = 'Tahoma'
    Font.Style = []
    ParentFont = False
    TabOrder = 5
    LookAndFeel.Kind = lfStandard
    object tvON: TcxGridDBTableView
      OnDblClick = tvONDblClick
      NavigatorButtons.ConfirmDelete = False
      NavigatorButtons.PriorPage.Visible = True
      NavigatorButtons.Next.Visible = True
      NavigatorButtons.Insert.Visible = True
      NavigatorButtons.Append.Visible = False
      NavigatorButtons.Edit.Visible = False
      NavigatorButtons.Post.Visible = True
      NavigatorButtons.Cancel.Visible = False
      NavigatorButtons.Refresh.Visible = False
      NavigatorButtons.SaveBookmark.Visible = False
      NavigatorButtons.GotoBookmark.Visible = False
      NavigatorButtons.Filter.Visible = False
      OnCustomDrawCell = tvONCustomDrawCell
      OnEditValueChanged = tvONEditValueChanged
      DataController.DataSource = dlgDS
      DataController.Summary.DefaultGroupSummaryItems = <>
      DataController.Summary.FooterSummaryItems = <
        item
          Format = '#,###0'
          Kind = skSum
          FieldName = 'ONVALUE'
          Column = tvONONVALUE
        end
        item
          Format = '#,###0'
          Kind = skSum
          FieldName = 'ONVYPLACHENO'
          Column = tvONONVYPLACHENO
        end>
      DataController.Summary.SummaryGroups = <>
      OptionsBehavior.CellHints = True
      OptionsCustomize.ColumnFiltering = False
      OptionsData.CancelOnExit = False
      OptionsView.CellEndEllipsis = True
      OptionsView.NoDataToDisplayInfoText = '<'#1053#1077#1090' '#1076#1072#1085#1085#1099#1093'>'
      OptionsView.CellAutoHeight = True
      OptionsView.CellTextMaxLineCount = 1
      OptionsView.ColumnAutoWidth = True
      OptionsView.Footer = True
      OptionsView.GroupByBox = False
      OptionsView.HeaderEndEllipsis = True
      OptionsView.Indicator = True
      Preview.Visible = True
      Styles.Header = DMInv.cxSiniyText
      object tvONONID: TcxGridDBColumn
        Caption = #8470
        DataBinding.FieldName = 'ONID'
        Options.Editing = False
        Width = 27
      end
      object tvONREASON: TcxGridDBColumn
        Caption = #1055#1088#1080#1095#1080#1085#1072' '#1076#1086#1087#1083'.'
        DataBinding.FieldName = 'REASON'
        Options.Editing = False
        Width = 67
      end
      object tvONONNOTE: TcxGridDBColumn
        Caption = #1057#1086#1076#1077#1088#1078#1072#1085#1080#1077
        DataBinding.FieldName = 'ONNOTE'
        Options.Editing = False
        Width = 78
      end
      object tvONONDATE: TcxGridDBColumn
        Caption = #1055#1077#1088#1080#1086#1076
        DataBinding.FieldName = 'ONDATE'
        PropertiesClassName = 'TcxDateEditProperties'
        Options.Editing = False
        Width = 35
      end
      object tvONONDATE_DOC: TcxGridDBColumn
        Caption = #1044#1072#1090#1072' '#1079#1072#1087#1080#1089#1082#1080
        DataBinding.FieldName = 'ONDATE_DOC'
        Options.Editing = False
        Width = 64
      end
      object tvONONVALUE: TcxGridDBColumn
        Caption = #1057#1091#1084#1084#1072
        DataBinding.FieldName = 'ONVALUE'
        Options.Editing = False
        Width = 46
      end
      object tvONONTIMEENTER: TcxGridDBColumn
        Caption = #1044#1072#1090#1072' '#1089#1086#1079#1076'.'
        DataBinding.FieldName = 'ONTIMEENTER'
        Options.Editing = False
        Width = 55
      end
      object tvONONTIMEEDIT: TcxGridDBColumn
        Caption = #1044#1072#1090#1072' '#1088#1077#1076#1072#1082#1090'.'
        DataBinding.FieldName = 'ONTIMEEDIT'
        Options.Editing = False
        Width = 62
      end
      object tvONPP_ENTER: TcxGridDBColumn
        Caption = #1040#1074#1090#1086#1088
        DataBinding.FieldName = 'PP_ENTER'
        Options.Editing = False
        Width = 31
      end
      object tvONPP_EDIT: TcxGridDBColumn
        Caption = #1056#1077#1076#1072#1082#1090#1086#1088
        DataBinding.FieldName = 'PP_EDIT'
        Options.Editing = False
        Width = 44
      end
      object tvONONOKNOTE: TcxGridDBColumn
        Caption = #1055#1088#1080#1084'. '#1082' '#1089#1090#1072#1090#1091#1089#1091
        DataBinding.FieldName = 'ONOKNOTE'
        Options.Editing = False
        Width = 75
      end
      object tvONONVYPLACHENO: TcxGridDBColumn
        Caption = #1050' '#1074#1099#1087#1083#1072#1090#1077
        DataBinding.FieldName = 'ONVYPLACHENO'
        Options.Editing = False
        Width = 58
      end
      object tvONONBACKNOTE: TcxGridDBColumn
        Caption = #1050#1086#1084#1084#1077#1085#1090#1072#1088#1080#1081' '#1076#1083#1103' '#1091#1090#1086#1095#1085#1077#1085#1080#1103
        DataBinding.FieldName = 'ONBACKNOTE'
        Options.Editing = False
        Width = 158
      end
      object tvONSTATUS: TcxGridDBColumn
        Caption = #1057#1090#1072#1090#1091#1089
        DataBinding.FieldName = 'STATUS'
        Options.Editing = False
        Width = 53
      end
      object tvONIS_PDF: TcxGridDBColumn
        Caption = 'PDF'
        DataBinding.FieldName = 'IS_PDF'
        PropertiesClassName = 'TcxCheckBoxProperties'
        Properties.NullStyle = nssUnchecked
        Properties.ValueChecked = 1
        Properties.ValueUnchecked = 0
        Options.Editing = False
      end
    end
    object cxGridLevel1: TcxGridLevel
      GridView = tvON
    end
  end
  object Panel2: TPanel [6]
    Left = 823
    Top = 96
    Width = 321
    Height = 145
    Color = clMoneyGreen
    Font.Charset = DEFAULT_CHARSET
    Font.Color = clBlack
    Font.Height = -11
    Font.Name = 'Tahoma'
    Font.Style = []
    ParentFont = False
    TabOrder = 6
    Visible = False
    object eAmount: TcxMaskEdit
      Left = 121
      Top = 34
      ParentFont = False
      Properties.MaskKind = emkRegExpr
      Properties.EditMask = '\d+'
      Properties.MaxLength = 0
      Style.Font.Charset = DEFAULT_CHARSET
      Style.Font.Color = clWindowText
      Style.Font.Height = -13
      Style.Font.Name = 'Tahoma'
      Style.Font.Style = []
      Style.IsFontAssigned = True
      TabOrder = 0
      Width = 72
    end
    object cxLabel4: TcxLabel
      Left = 6
      Top = 53
      Caption = #1050#1086#1084#1084#1077#1085#1090'.'
    end
    object eNote: TcxTextEdit
      Left = 8
      Top = 74
      ParentFont = False
      Style.Font.Charset = DEFAULT_CHARSET
      Style.Font.Color = clWindowText
      Style.Font.Height = -13
      Style.Font.Name = 'Tahoma'
      Style.Font.Style = []
      Style.IsFontAssigned = True
      TabOrder = 2
      Width = 305
    end
    object bVyplOk: TcxButton
      Left = 65
      Top = 106
      Width = 56
      Height = 23
      Caption = #1054#1050
      TabOrder = 3
      OnClick = bVyplOkClick
      Glyph.Data = {
        BE060000424DBE06000000000000360400002800000024000000120000000100
        0800000000008802000000000000000000000001000000000000000000000000
        80000080000000808000800000008000800080800000C0C0C000C0DCC000F0C8
        A400000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        0000000000000000000000000000000000000000000000000000000000000000
        000000000000000000000000000000000000F0FBFF00A4A0A000808080000000
        FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00030303030303
        0303030303030303030303030303030303030303030303030303030303030303
        03030303030303030303030303030303030303030303FF030303030303030303
        03030303030303040403030303030303030303030303030303F8F8FF03030303
        03030303030303030303040202040303030303030303030303030303F80303F8
        FF030303030303030303030303040202020204030303030303030303030303F8
        03030303F8FF0303030303030303030304020202020202040303030303030303
        0303F8030303030303F8FF030303030303030304020202FA0202020204030303
        0303030303F8FF0303F8FF030303F8FF03030303030303020202FA03FA020202
        040303030303030303F8FF03F803F8FF0303F8FF03030303030303FA02FA0303
        03FA0202020403030303030303F8FFF8030303F8FF0303F8FF03030303030303
        FA0303030303FA0202020403030303030303F80303030303F8FF0303F8FF0303
        0303030303030303030303FA0202020403030303030303030303030303F8FF03
        03F8FF03030303030303030303030303FA020202040303030303030303030303
        0303F8FF0303F8FF03030303030303030303030303FA02020204030303030303
        03030303030303F8FF0303F8FF03030303030303030303030303FA0202020403
        030303030303030303030303F8FF0303F8FF03030303030303030303030303FA
        0202040303030303030303030303030303F8FF03F8FF03030303030303030303
        03030303FA0202030303030303030303030303030303F8FFF803030303030303
        030303030303030303FA0303030303030303030303030303030303F803030303
        0303030303030303030303030303030303030303030303030303030303030303
        0303}
      NumGlyphs = 2
    end
    object cxLabel5: TcxLabel
      Left = 138
      Top = 8
      Caption = #1057#1091#1084#1084#1072
    end
    object cxButton1: TcxButton
      Left = 193
      Top = 106
      Width = 80
      Height = 23
      Caption = #1054#1090#1084#1077#1085#1072
      TabOrder = 5
      OnClick = cxButton1Click
    end
  end
  object cxMemo1: TcxMemo [7]
    Left = 640
    Top = 192
    Lines.Strings = (
      'cxMemo1')
    TabOrder = 7
    Visible = False
    Height = 321
    Width = 489
  end
  object cxMemo2: TcxMemo [8]
    Left = 48
    Top = 192
    Lines.Strings = (
      'cxMemo2')
    TabOrder = 8
    Visible = False
    Height = 329
    Width = 401
  end
  inherited dlgDS: TDataSource
    DataSet = qON
  end
  object qON: TIBQuery
    Database = DMInv.DBRead
    Transaction = DMInv.IBTransaction1
    AfterInsert = qONAfterInsert
    BeforeOpen = qONBeforeOpen
    CachedUpdates = True
    DataSource = dsPON
    SQL.Strings = (
      
        'SELECT O.*, sd.SDNAME AS reason, p.PLASTNAME||'#39' '#39'||SUBSTRING(p.P' +
        'NAME FROM 1 FOR 1 )||'#39'. '#39'||'
      
        'COALESCE(SUBSTRING(p.PPATRONYMIC FROM 1 FOR 1)||'#39'.'#39','#39' '#39') AS PP_e' +
        'nter,'
      'p1.PLASTNAME||'#39' '#39'||SUBSTRING(p1.PNAME FROM 1 FOR 1 )||'#39'. '#39'||'
      
        'COALESCE(SUBSTRING(p1.PPATRONYMIC FROM 1 FOR 1)||'#39'.'#39','#39' '#39') AS PP_' +
        'edit,'
      'CASE'
      'WHEN (O.ONISOK IS NULL) THEN '#39#1053#1077' '#1088#1072#1089#1089#1084#1086#1090#1088#1077#1085#1086#39
      'WHEN O.ONISOK = 1 THEN '#39#1056#1072#1089#1089#1084#1086#1090#1088#1077#1085#1086#39
      'WHEN O.ONISOK = 2 THEN '#39#1054#1090#1082#1072#1079#1072#1085#1086#39
      'END AS status, IIF(o.ONFILE is NULL, 0, 1) AS is_pdf'
      'FROM OFFICIAL_NOTE O'
      'LEFT OUTER JOIN SYS_DIC sd ON sd.SDID = o.SDID'
      'LEFT OUTER JOIN USERS ue ON ue.USNAME = O.ONUSERENTER'
      'LEFT OUTER JOIN PEOPLE P ON P.PID = ue.PID'
      'LEFT OUTER JOIN USERS ued ON ued.USNAME = O.ONUSEREDIT'
      'LEFT OUTER JOIN PEOPLE P1 ON P1.PID = ued.PID'
      'WHERE O.PID_EMPL = :PID_EMPL'
      '    AND O.ONDATE_DOC BETWEEN :data1 AND :data2'
      '    AND o.ONISDELETE IS NULL')
    UpdateObject = quON
    GeneratorField.Field = 'ONID'
    GeneratorField.Generator = 'GEN_OFFICIAL_NOTE_ID'
    Left = 296
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'PID_EMPL'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data1'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data2'
        ParamType = ptUnknown
      end>
    object qONONID: TIntegerField
      FieldName = 'ONID'
      Origin = '"OFFICIAL_NOTE"."ONID"'
      ProviderFlags = [pfInUpdate, pfInWhere, pfInKey]
      Required = True
    end
    object qONPID_EMPL: TIntegerField
      FieldName = 'PID_EMPL'
      Origin = '"OFFICIAL_NOTE"."PID_EMPL"'
    end
    object qONSDID: TIntegerField
      FieldName = 'SDID'
      Origin = '"OFFICIAL_NOTE"."SDID"'
    end
    object qONONDATE: TDateField
      FieldName = 'ONDATE'
      Origin = '"OFFICIAL_NOTE"."ONDATE"'
    end
    object qONONVALUE: TIBBCDField
      FieldName = 'ONVALUE'
      Origin = '"OFFICIAL_NOTE"."ONVALUE"'
      DisplayFormat = '#,###0'
      EditFormat = '0'
      Precision = 18
      Size = 2
    end
    object qONONISOK: TIntegerField
      FieldName = 'ONISOK'
      Origin = '"OFFICIAL_NOTE"."ONISOK"'
    end
    object qONONOKNOTE: TIBStringField
      FieldName = 'ONOKNOTE'
      Origin = '"OFFICIAL_NOTE"."ONOKNOTE"'
      Size = 255
    end
    object qONONUSERENTER: TIBStringField
      FieldName = 'ONUSERENTER'
      Origin = '"OFFICIAL_NOTE"."ONUSERENTER"'
      Size = 40
    end
    object qONONTIMEENTER: TDateTimeField
      FieldName = 'ONTIMEENTER'
      Origin = '"OFFICIAL_NOTE"."ONTIMEENTER"'
    end
    object qONONUSEREDIT: TIBStringField
      FieldName = 'ONUSEREDIT'
      Origin = '"OFFICIAL_NOTE"."ONUSEREDIT"'
      Size = 40
    end
    object qONONTIMEEDIT: TDateTimeField
      FieldName = 'ONTIMEEDIT'
      Origin = '"OFFICIAL_NOTE"."ONTIMEEDIT"'
    end
    object qONONISDELETE: TIntegerField
      FieldName = 'ONISDELETE'
      Origin = '"OFFICIAL_NOTE"."ONISDELETE"'
    end
    object qONREASON: TIBStringField
      FieldName = 'REASON'
      Origin = '"SYS_DIC"."SDNAME"'
      Size = 255
    end
    object qONPP_ENTER: TIBStringField
      FieldName = 'PP_ENTER'
      ProviderFlags = []
      Size = 769
    end
    object qONPP_EDIT: TIBStringField
      FieldName = 'PP_EDIT'
      ProviderFlags = []
      Size = 769
    end
    object qONONDATE_DOC: TDateField
      FieldName = 'ONDATE_DOC'
      Origin = '"OFFICIAL_NOTE"."ONDATE_DOC"'
    end
    object qONONVYPLACHENO: TIBBCDField
      FieldName = 'ONVYPLACHENO'
      Origin = '"OFFICIAL_NOTE"."ONVYPLACHENO"'
      DisplayFormat = '#,###0'
      Precision = 18
      Size = 2
    end
    object qONONBACKNOTE: TIBStringField
      FieldName = 'ONBACKNOTE'
      Origin = '"OFFICIAL_NOTE"."ONBACKNOTE"'
      Size = 255
    end
    object qONONFILE: TBlobField
      FieldName = 'ONFILE'
      Origin = '"OFFICIAL_NOTE"."ONFILE"'
      ProviderFlags = [pfInUpdate]
      Size = 8
    end
    object qONSTATUS: TIBStringField
      FieldName = 'STATUS'
      ProviderFlags = []
      FixedChar = True
      Size = 14
    end
    object qONIS_PDF: TIntegerField
      FieldName = 'IS_PDF'
      ProviderFlags = []
    end
    object qONONNOTE: TIBStringField
      FieldName = 'ONNOTE'
      Origin = '"OFFICIAL_NOTE"."ONNOTE"'
      Size = 2048
    end
    object qONONISVYPLACHENO: TIntegerField
      FieldName = 'ONISVYPLACHENO'
      Origin = '"OFFICIAL_NOTE"."ONISVYPLACHENO"'
    end
  end
  object quON: TIBUpdateSQL
    RefreshSQL.Strings = (
      'Select '
      '  ONID,'
      '  PID_EMPL,'
      '  SDID,'
      '  ONNOTE,'
      '  ONDATE,'
      '  ONDATE_DOC,'
      '  ONVALUE,'
      '  ONISOK,'
      '  ONOKNOTE,'
      '  ONUSERENTER,'
      '  ONTIMEENTER,'
      '  ONUSEREDIT,'
      '  ONTIMEEDIT,'
      '  ONISDELETE,'
      '  ONVYPLACHENO,'
      '  ONBACKNOTE,'
      '  ONFILE'
      'from OFFICIAL_NOTE '
      'where'
      '  ONID = :ONID')
    ModifySQL.Strings = (
      'update OFFICIAL_NOTE'
      'set'
      '  ONBACKNOTE = :ONBACKNOTE,'
      '  ONDATE = :ONDATE,'
      '  ONDATE_DOC = :ONDATE_DOC,'
      '  ONFILE = :ONFILE,'
      '  ONID = :ONID,'
      '  ONISDELETE = :ONISDELETE,'
      '  ONISOK = :ONISOK,'
      '  ONNOTE = :ONNOTE,'
      '  ONOKNOTE = :ONOKNOTE,'
      '  ONVALUE = :ONVALUE,'
      '  ONVYPLACHENO = :ONVYPLACHENO,'
      '  PID_EMPL = :PID_EMPL,'
      '  SDID = :SDID'
      'where'
      '  ONID = :OLD_ONID')
    InsertSQL.Strings = (
      'insert into OFFICIAL_NOTE'
      
        '  (ONBACKNOTE, ONDATE, ONDATE_DOC, ONFILE, ONID, ONISDELETE, ONI' +
        'SOK, ONNOTE, '
      '   ONOKNOTE, ONVALUE, ONVYPLACHENO, PID_EMPL, SDID)'
      'values'
      
        '  (:ONBACKNOTE, :ONDATE, :ONDATE_DOC, :ONFILE, :ONID, :ONISDELET' +
        'E, :ONISOK, '
      
        '   :ONNOTE, :ONOKNOTE, :ONVALUE, :ONVYPLACHENO, :PID_EMPL, :SDID' +
        ')')
    DeleteSQL.Strings = (
      'update OFFICIAL_NOTE'
      'set'
      '  ONISDELETE = 1'
      'where'
      '  ONID = :OLD_ONID')
    Left = 336
  end
  object dsPON: TDataSource
    DataSet = qPON
    Left = 256
    Top = 104
  end
  object qPON: TIBQuery
    Database = DMInv.DBRead
    Transaction = DMInv.IBTransaction1
    CachedUpdates = True
    SQL.Strings = (
      
        'SELECT DISTINCT O.PID_EMPL, p.PLASTNAME||'#39' '#39'||SUBSTRING(p.PNAME ' +
        'FROM 1 FOR 1 )||'#39'. '#39'||'
      
        'COALESCE(SUBSTRING(p.PPATRONYMIC FROM 1 FOR 1)||'#39'.'#39','#39' '#39') AS PP, ' +
        'sel.sum_, sel1.sum_2 AS itogo,'
      
        'CAST(:data3 AS DATE) AS data1, CAST(:data4 AS DATE) AS data2 , s' +
        'el2.sum_3 as ne_vypl,'
      'neopl.sum_4 kvyplate'
      'FROM OFFICIAL_NOTE O'
      'INNER JOIN PEOPLE P ON P.PID = O.PID_EMPL'
      'LEFT OUTER JOIN'
      '('
      'SELECT ON1.PID_EMPL, SUM(ON1.ONVYPLACHENO) AS sum_'
      'FROM OFFICIAL_NOTE ON1'
      'WHERE on1.ONISOK = 1'
      
        '    AND ON1.ONDATE BETWEEN IIF(CURRENT_DATE < ('#39'01.09.'#39'|| EXTRAC' +
        'T(YEAR FROM CURRENT_DATE)), '#39'01.09.'#39'||(EXTRACT(YEAR FROM CURRENT' +
        '_DATE)-1), '#39'01.09.'#39'||EXTRACT(YEAR FROM CURRENT_DATE)) AND CURREN' +
        'T_DATE'
      '    AND ON1.ONISVYPLACHENO = 1'
      '    AND ON1.ONISDELETE IS NULL'
      'GROUP BY 1'
      ') AS sel ON sel.pid_empl = o.PID_EMPL'
      'LEFT OUTER JOIN'
      '('
      'SELECT ON1.PID_EMPL, SUM(ON1.ONVYPLACHENO) AS sum_2'
      'FROM OFFICIAL_NOTE ON1'
      'WHERE on1.ONISOK = 1'
      '    AND ON1.ONDATE BETWEEN :data1 AND :data2'
      '    AND ON1.ONISVYPLACHENO = 1'
      '    AND ON1.ONISDELETE IS NULL'
      'GROUP BY 1'
      ') AS sel1 ON sel1.pid_empl = o.PID_EMPL'
      'LEFT OUTER JOIN'
      '('
      'SELECT ON1.PID_EMPL, SUM(ON1.ONVALUE) AS sum_3'
      'FROM OFFICIAL_NOTE ON1'
      'WHERE on1.ONISOK IS null'
      '    AND ON1.ONDATE BETWEEN :data1 AND :data2'
      '    AND ON1.ONISDELETE IS NULL'
      'GROUP BY 1'
      ') AS sel2 ON sel2.pid_empl = o.PID_EMPL'
      'LEFT OUTER JOIN'
      '('
      'SELECT ON1.PID_EMPL, SUM(ON1.ONVALUE) AS sum_4'
      'FROM OFFICIAL_NOTE ON1'
      'WHERE on1.ONISOK = 1'
      '    AND ON1.ONISVYPLACHENO IS null'
      '    AND ON1.ONDATE BETWEEN :data1 AND :data2'
      '    AND ON1.ONISDELETE IS NULL'
      'GROUP BY 1'
      ') AS neopl ON neopl.pid_empl = o.PID_EMPL'
      'WHERE O.ONDATE BETWEEN :data3 AND :data4'
      ' AND o.ONISDELETE IS NULL')
    GeneratorField.Field = 'ONID'
    Left = 296
    Top = 104
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'data3'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data4'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data1'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data2'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data1'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data2'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data1'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data2'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data3'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data4'
        ParamType = ptUnknown
      end>
    object qPONPID_EMPL: TIntegerField
      FieldName = 'PID_EMPL'
      Origin = '"OFFICIAL_NOTE"."PID_EMPL"'
    end
    object qPONPP: TIBStringField
      FieldName = 'PP'
      ProviderFlags = []
      Size = 769
    end
    object qPONSUM_: TIBBCDField
      FieldName = 'SUM_'
      ProviderFlags = []
      DisplayFormat = '#,###0'
      Precision = 18
      Size = 2
    end
    object qPONITOGO: TIBBCDField
      FieldName = 'ITOGO'
      ProviderFlags = []
      DisplayFormat = '#,###0'
      Precision = 18
      Size = 2
    end
    object qPONDATA1: TDateField
      FieldName = 'DATA1'
      ProviderFlags = []
    end
    object qPONDATA2: TDateField
      FieldName = 'DATA2'
      ProviderFlags = []
    end
    object qPONNE_VYPL: TIBBCDField
      FieldName = 'NE_VYPL'
      ProviderFlags = []
      DisplayFormat = '#,###0'
      Precision = 18
      Size = 2
    end
    object qPONKVYPLATE: TIBBCDField
      FieldName = 'KVYPLATE'
      ProviderFlags = []
      DisplayFormat = '#,###0'
      Precision = 18
      Size = 2
    end
  end
  object cxPropertiesStore1: TcxPropertiesStore
    Components = <
      item
        Component = dbgON
        Properties.Strings = (
          'Height'
          'Left'
          'Top'
          'Width')
      end
      item
        Component = dbgPeople
        Properties.Strings = (
          'Height'
          'Left'
          'Top'
          'Width')
      end
      item
        Component = tvON
        Properties.Strings = (
          'BackgroundBitmaps'
          'DataController'
          'DateTimeHandling'
          'DragMode'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FilterBox'
          'Filtering'
          'FilterRow'
          'Name'
          'NavigatorButtons'
          'NewItemRow'
          'OptionsBehavior'
          'OptionsCustomize'
          'OptionsData'
          'OptionsSelection'
          'OptionsView'
          'PopupMenu'
          'Preview'
          'Styles'
          'Synchronization'
          'Tag')
      end
      item
        Component = tvONIS_PDF
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONONBACKNOTE
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONONDATE
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONONDATE_DOC
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONONID
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONONNOTE
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONONOKNOTE
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONONTIMEEDIT
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONONTIMEENTER
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONONVALUE
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONONVYPLACHENO
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONPP_EDIT
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONPP_ENTER
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONREASON
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvONSTATUS
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvPeople
        Properties.Strings = (
          'BackgroundBitmaps'
          'DataController'
          'DateTimeHandling'
          'DragMode'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FilterBox'
          'Filtering'
          'FilterRow'
          'Name'
          'NavigatorButtons'
          'NewItemRow'
          'OptionsBehavior'
          'OptionsCustomize'
          'OptionsData'
          'OptionsSelection'
          'OptionsView'
          'PopupMenu'
          'Preview'
          'Styles'
          'Synchronization'
          'Tag')
      end
      item
        Component = tvPeopleITOGO
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvPeopleKVYPLATE
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvPeopleNE_VYPL
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvPeoplePP
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end
      item
        Component = tvPeopleSUM_
        Properties.Strings = (
          'AlternateCaption'
          'BestFitMaxWidth'
          'Caption'
          'DataBinding'
          'DateTimeGrouping'
          'FakeComponentLink1'
          'FakeComponentLink2'
          'FakeComponentLink3'
          'FooterAlignmentHorz'
          'GroupIndex'
          'GroupSummaryAlignment'
          'HeaderAlignmentHorz'
          'HeaderAlignmentVert'
          'HeaderGlyph'
          'HeaderGlyphAlignmentHorz'
          'HeaderGlyphAlignmentVert'
          'MinWidth'
          'Name'
          'Options'
          'Properties'
          'PropertiesClassName'
          'RepositoryItem'
          'SortIndex'
          'SortOrder'
          'Styles'
          'Summary'
          'Tag'
          'Visible'
          'VisibleForCustomization'
          'Width')
      end>
    StorageName = 'Software\Olympic_PS_fmOfficialNote'
    StorageType = stRegistry
    Left = 480
    Top = 112
  end
  object qPON_tmp: TIBQuery
    Database = DMInv.DBRead
    Transaction = DMInv.IBTransaction1
    DataSource = dsPON
    SQL.Strings = (
      
        'SELECT DISTINCT O.PID_EMPL, p.PLASTNAME||'#39' '#39'||SUBSTRING(p.PNAME ' +
        'FROM 1 FOR 1 )||'#39'. '#39'||'
      
        'COALESCE(SUBSTRING(p.PPATRONYMIC FROM 1 FOR 1)||'#39'.'#39','#39' '#39') AS PP, ' +
        'sel.sum_, sel1.sum_2 AS itogo,'
      
        'CAST(:data3 AS DATE) AS data1, CAST(:data4 AS DATE) AS data2 , s' +
        'el2.sum_3 as ne_vypl,'
      'neopl.sum_4 kvyplate'
      'FROM OFFICIAL_NOTE O'
      'INNER JOIN PEOPLE P ON P.PID = O.PID_EMPL'
      'LEFT OUTER JOIN'
      '('
      'SELECT ON1.PID_EMPL, SUM(ON1.ONVYPLACHENO) AS sum_'
      'FROM OFFICIAL_NOTE ON1'
      'WHERE on1.ONISOK = 1'
      
        '    AND ON1.ONDATE BETWEEN IIF(CURRENT_DATE < ('#39'01.09.'#39'|| EXTRAC' +
        'T(YEAR FROM CURRENT_DATE)), '#39'01.09.'#39'||(EXTRACT(YEAR FROM CURRENT' +
        '_DATE)-1), '#39'01.09.'#39'||EXTRACT(YEAR FROM CURRENT_DATE)) AND CURREN' +
        'T_DATE'
      '    AND ON1.ONISVYPLACHENO = 1'
      '    AND ON1.ONISDELETE IS NULL'
      'GROUP BY 1'
      ') AS sel ON sel.pid_empl = o.PID_EMPL'
      'LEFT OUTER JOIN'
      '('
      'SELECT ON1.PID_EMPL, SUM(ON1.ONVYPLACHENO) AS sum_2'
      'FROM OFFICIAL_NOTE ON1'
      'WHERE on1.ONISOK = 1'
      '    AND ON1.ONDATE BETWEEN :data1 AND :data2'
      '    AND ON1.ONISVYPLACHENO = 1'
      '    AND ON1.ONISDELETE IS NULL'
      'GROUP BY 1'
      ') AS sel1 ON sel1.pid_empl = o.PID_EMPL'
      'LEFT OUTER JOIN'
      '('
      'SELECT ON1.PID_EMPL, SUM(ON1.ONVALUE) AS sum_3'
      'FROM OFFICIAL_NOTE ON1'
      'WHERE on1.ONISOK IS null'
      '    AND ON1.ONDATE BETWEEN :data1 AND :data2'
      '    AND ON1.ONISDELETE IS NULL'
      'GROUP BY 1'
      ') AS sel2 ON sel2.pid_empl = o.PID_EMPL'
      'LEFT OUTER JOIN'
      '('
      'SELECT ON1.PID_EMPL, SUM(ON1.ONVALUE) AS sum_4'
      'FROM OFFICIAL_NOTE ON1'
      'WHERE on1.ONISOK = 1'
      '    AND ON1.ONISVYPLACHENO IS null'
      '    AND ON1.ONDATE BETWEEN :data1 AND :data2'
      '    AND ON1.ONISDELETE IS NULL'
      'GROUP BY 1'
      ') AS neopl ON neopl.pid_empl = o.PID_EMPL'
      'WHERE O.ONDATE BETWEEN :data3 AND :data4'
      ' AND o.ONISDELETE IS NULL')
    GeneratorField.Field = 'ONID'
    Left = 296
    Top = 136
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'data3'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data4'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data1'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data2'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data1'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data2'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data1'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data2'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data3'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data4'
        ParamType = ptUnknown
      end>
  end
  object SD1: TSaveDialog
    InitialDir = 'c:\'
    Options = [ofOverwritePrompt, ofHideReadOnly, ofEnableSizing]
    Left = 176
    Top = 112
  end
  object qon_temp: TIBQuery
    Database = DMInv.DBRead
    Transaction = DMInv.IBTransaction1
    BeforeOpen = qONBeforeOpen
    DataSource = dsPON
    SQL.Strings = (
      
        'SELECT O.*, sd.SDNAME AS reason, p.PLASTNAME||'#39' '#39'||SUBSTRING(p.P' +
        'NAME FROM 1 FOR 1 )||'#39'. '#39'||'
      
        'COALESCE(SUBSTRING(p.PPATRONYMIC FROM 1 FOR 1)||'#39'.'#39','#39' '#39') AS PP_e' +
        'nter,'
      'p1.PLASTNAME||'#39' '#39'||SUBSTRING(p1.PNAME FROM 1 FOR 1 )||'#39'. '#39'||'
      
        'COALESCE(SUBSTRING(p1.PPATRONYMIC FROM 1 FOR 1)||'#39'.'#39','#39' '#39') AS PP_' +
        'edit,'
      'CASE'
      'WHEN (O.ONISOK IS NULL) THEN '#39#1053#1077' '#1088#1072#1089#1089#1084#1086#1090#1088#1077#1085#1086#39
      'WHEN O.ONISOK = 1 THEN '#39#1056#1072#1089#1089#1084#1086#1090#1088#1077#1085#1086#39
      'WHEN O.ONISOK = 2 THEN '#39#1054#1090#1082#1072#1079#1072#1085#1086#39
      'END AS status, IIF(o.ONFILE is NULL, 0, 1) AS is_pdf'
      'FROM OFFICIAL_NOTE O'
      'LEFT OUTER JOIN SYS_DIC sd ON sd.SDID = o.SDID'
      'LEFT OUTER JOIN USERS ue ON ue.USNAME = O.ONUSERENTER'
      'LEFT OUTER JOIN PEOPLE P ON P.PID = ue.PID'
      'LEFT OUTER JOIN USERS ued ON ued.USNAME = O.ONUSEREDIT'
      'LEFT OUTER JOIN PEOPLE P1 ON P1.PID = ued.PID'
      'WHERE O.PID_EMPL = :PID_EMPL'
      '    AND O.ONDATE_DOC BETWEEN :data1 AND :data2'
      '    AND o.ONISDELETE IS NULL')
    GeneratorField.Field = 'ONID'
    Left = 296
    Top = 32
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'PID_EMPL'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data1'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data2'
        ParamType = ptUnknown
      end>
  end
  object sqlUpdate: TIBSQL
    Database = DMInv.DBRead
    SQL.Strings = (
      'UPDATE OFFICIAL_NOTE N'
      'SET N.ONISVYPLACHENO = 1'
      'WHERE N.PID_EMPL = :PID_EMPL and'
      'N.ONISVYPLACHENO IS NULL and n.ONISOK = 1')
    Transaction = DMInv.IBTransaction1
    Left = 144
    Top = 8
  end
end
